<%@ page language="java" contentType="text/html; charset=UTF-8"
    pageEncoding="UTF-8"%>
     <%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core"  %>
<%@ taglib prefix="fmt" uri="http://java.sun.com/jsp/jstl/fmt"  %>
<%@ taglib prefix="fn" uri="http://java.sun.com/jsp/jstl/functions"  %>
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>Insert title here</title>
<script src="http://ajax.googleapis.com/ajax/libs/jquery/1.10.2/jquery.min.js">
		</script>
<script type="text/javascript">
//點驗證碼圖片可以更換新的一組驗證碼
function getSecureNumber(){ 
	 $('#securenumber').attr("src","<c:url value='/SecurePic.controller'/>");
	 }

</script>
</head>
<body>

<h3>Login</h3>

<form action="<c:url value='/secure/LoginServlet.controller'/>" method="post">
<table>
	<tr>
		<td>ID : </td>
		<td><input type="text" name="account" value="${account}"></td>
		<td>${errors.account}</td>
	</tr>
	<tr>
		<td>PWD : </td>
		<td><input type="text" name="password" value="${password}"></td>
		<td>${errors.password}</td>
	</tr>
	<tr>
		<td><img id="securenumber" src="<c:url value='/SecurePic.controller' />"  onclick="getSecureNumber()"/></td>
		<td><input type="text" name="securenumber" value=""></td>
		<td>${errors.securenumber}</td>
	</tr>
	<tr>
		<td>　</td>
		<td align="right"><input type="submit" value="Login"></td>
	</tr>
	<tr>
	    <td>　</td>
	    <td>${errors.login} </td>
	</tr>
</table>
</form>

</body>
</html>